The invention generally relates to computer systems and, more particularly, the invention relates to processing graphics request data for stereoscopic display on a computer display device.
Images may be stereoscopically drawn on a display device in accord with many well known techniques. Among those techniques is one in which a first set of (horizontal) lines on the display is directed to a viewer""s right eye, while a second set of different lines on the display is directed the viewer""s left eye. For example, every odd line may be directed to the viewer""s left eye only, while every even line may be directed to the viewer""s right eye only. To stereoscopically view an image utilizing this technique, the viewer generally must wear a pair of polarized glasses that blocks the first set of lines from view by the left eye, and similarly blocks the second set of lines from view by the right eye. The combined effect viewed by both eyes produces the stereoscopic image.
As is known in the art, many conventionally known computer graphical application program interfaces, such as the OPENGL(trademark) API (available from Silicon Graphics, Inc. of Mountain View, Calif.), break an image into a plurality of primitive shapes (xe2x80x9cprimitivesxe2x80x9d), such as lines and points, to display the image. Each primitive of the image is rendered to produce the final displayed image. Display problems a rise, however, when primitives are stereoscopically drawn across a small, odd number of lines of the display device. For example, only one eye of a viewer will see a horizontal line (i.e., drawn on one line of the display device), while the other eye will not see such line. This distorts the ultimate stereoscopic image, thus degrading the visual effect of the display.
In a similar manner, because of commonly known aliasing problems, a line drawn at less than or equal to a forty-five degree angle from the horizontal of a display device also is distorted. As shown in FIG. 1, such a line often lights several consecutive pixels in each of several lines to create a stair effect. Each eye thus sees every other part of the line, effectively creating the illusion of a discontinuous line.
In accordance with one aspect of the invention, a method, computer program product, and graphics processor for stereoscopically displaying a primitive on a display device adds a row of pixels to the primitive to improve its appearance on the display device. To that end, it first is determined if the primitive is to be stereoscopically displayed on the display device. After it is determined that the primitive is to be stereoscopically displayed, then a row of pixels is added to the primitive. The primitive preferably is a point primitive or a line primitive.
In accordance with another aspect of the invention, a method and apparatus improves the appearance of a graphical image for subsequent display on a display device. The graphical image is comprised of a plurality of primitives that each have an associated width. Accordingly, graphics request code representing the plurality of primitives;is received. It then is determined if the plurality of primitives are to be displayed in a stereoscopic display mode. If the plurality of primitives is determined to be in the stereoscopic display mode, then the width is increased, by one pixel, of a set of the plurality of primitives.